﻿using System;
using System.Collections.Generic;
using MTC.DataAccess;

namespace MTC.Business.Schedule
{
    public class Schedule
    {
        public static List<Common.DTO.Schedule> GetSchedules()
        {
            return ScheduleDataAccess.GetSchedules();
        }


        public static bool DeleteSchedule(DateTime scheduleDate, int shiftId)
        {
            return ScheduleDataAccess.DeleteSchedule(scheduleDate, shiftId);
        }

        //public static List<Common.DTO.Schedule> GetSchedule(int scheduleId)
        //{
        //    if (scheduleId == 0) throw new ArgumentNullException("ScheduleId");
        //    return ScheduleDataAccess.GetSchedule(scheduleId);
        //}


        private static bool IsValidSchedule(MTC.Common.DTO.Schedule schedule)
        {
            return true;
        }

        public static List<Common.DTO.Schedule> GetASchedule(DateTime schedule, int shiftId)
        {
            return ScheduleDataAccess.GetASchedule(schedule, shiftId);
        }

        public static List<MTC.Common.DTO.Schedule> CreateASchedule(DateTime schedule, int shift)
        {
            return ScheduleDataAccess.CreateASchedule(schedule, shift);
        }

        public static bool UpdateASchedule(int ScheduleDriverTaxiId, int DriverId)
        {
            return ScheduleDataAccess.UpdateASchedule(ScheduleDriverTaxiId, DriverId); 
        }

        public static bool CheckSchedule(DateTime schedule, int shift)
        {
            return ScheduleDataAccess.CheckSchedule(schedule, shift); 
        }
    }
}
